// Package mynum
// @Author: zhangdi
// @File: generics
// @Version: 1.0.0
// @Date: 2023/10/16 13:56
package mynum

type Int interface {
	int | int8 | int16 | int32 | int64
}

type Uint interface {
	uint | uint8 | uint16 | uint32
}

type Float interface {
	float32 | float64
}

// Slice 一个可以容纳所有int,uint以及浮点类型的泛型切片
type Slice[T int | int8 | int16 | int32 | int64 | uint | uint8 | uint16 | uint32 | uint64 | float32 | float64] []T

type SliceElement interface {
	Int | Uint | Float
}

type Numbers interface {
	uint | int | uint16 | uint8 | uint64 | uint32 | int8 | int16 | int32 | int64
}
